package com.siwei.mes.service.sync.erp;

import com.github.pagehelper.PageInfo;
import com.siwei.mes.common.query.PageQuery;
import com.siwei.mes.entity.sync.erp.ErpSupplierCompanyMaterials;

import java.util.List;

/**
 * ERP-供应商原材料(ErpSupplierCompanyMaterials)表服务接口
 *
 * @author linzi
 * @since 2024-08-17 09:51:17
 */
public interface ErpSupplierCompanyMaterialsService {

    /**
     * 新增
     *
     * @param entity
     * @return
     */
    Long create(ErpSupplierCompanyMaterials entity);

    /**
     * 修改
     *
     * @param entity
     */
    void update(ErpSupplierCompanyMaterials entity);

    /**
     * 删除
     *
     * @param id
     */
    void delete(Long id);

    /**
     * 获取所有分组  分页
     *
     * @param query
     * @return
     */
    PageInfo<ErpSupplierCompanyMaterials> getPage(PageQuery<ErpSupplierCompanyMaterials, ErpSupplierCompanyMaterials> query);

    /**
     * 根据id查询
     *
     * @param id
     * @return
     */
    ErpSupplierCompanyMaterials loadById(Long id);

    /**
     * 获取所有
     *
     * @param entity
     * @return
     */
    List<ErpSupplierCompanyMaterials> getAll(ErpSupplierCompanyMaterials entity);


    /**
     * 同步数据新增或修改
     *
     * @param entity
     */
    void syncSaveOrUpdate(ErpSupplierCompanyMaterials entity);
}
